﻿<Window
	xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
	xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
	xmlns:xctk="http://schemas.xceed.com/wpf/xaml/toolkit"
	xmlns:d="http://schemas.microsoft.com/expression/blend/2008" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" mc:Ignorable="d"
	x:Class="SeismicResponseSpectrum.Ui.ExportDiagramWindow"
	x:Name="Window"
	Title="Export Diagram"
	Width="600" Height="300" >

    <Grid x:Name="LayoutRoot">
        <Grid.ColumnDefinitions>
            <ColumnDefinition Width="47*"/>
            <ColumnDefinition Width="49*"/>
            <ColumnDefinition Width="77*"/>
            <ColumnDefinition Width="131*"/>
            <ColumnDefinition Width="64*"/>
            <ColumnDefinition Width="224*"/>
        </Grid.ColumnDefinitions>
        <Grid.RowDefinitions>
            <RowDefinition Height="35"/>
            <RowDefinition Height="35"/>
            <RowDefinition Height="35"/>
            <RowDefinition Height="35"/>
            <RowDefinition Height="35"/>
            <RowDefinition />
            <RowDefinition Height="32"/>
        </Grid.RowDefinitions>
        <TextBlock TextWrapping="Wrap" VerticalAlignment="Center" Margin="10" Height="15" Grid.ColumnSpan="4"><Run Text="Export Diagram As"/></TextBlock>
        <RadioButton x:Name="radioButton" Content="PNG File (bitmap)" Grid.Row="1" VerticalAlignment="Center" Margin="5,10" Grid.ColumnSpan="2" Grid.Column="1" IsChecked="{Binding ExportPng}" Height="15"/>
        <RadioButton Content="XAML File (vector)" Grid.Row="3" VerticalAlignment="Center" Margin="5,10" Grid.ColumnSpan="2" Grid.Column="1" IsChecked="{Binding ExportXaml}" Height="15"/>
        <StackPanel Margin="0" Orientation="Horizontal" Grid.Row="6" HorizontalAlignment="Right" Grid.Column="5" Width="115">
            <Button Content="OK" HorizontalAlignment="Right" Margin="5,5,0,5" MinWidth="50" IsDefault="True" Click="Button_Click" />
            <Button Content="Cancel" HorizontalAlignment="Right" Margin="5" MinWidth="50" IsCancel="True" />
        </StackPanel>
        <TextBlock Margin="5,5,0,0" Grid.Row="2" TextWrapping="Wrap" Text="DPI" Grid.Column="2"/>
        <xctk:IntegerUpDown Grid.Column="3" Margin="5" Grid.Row="2" Value="{Binding PngDpi}"  Minimum="75" IsEnabled="{Binding IsChecked, ElementName=radioButton}"/>
        <TextBlock Grid.Column="4" Margin="5" Grid.Row="2" TextWrapping="Wrap" Text="{Binding DpiQuality}" Visibility="Collapsed"/>
        <Image Source="{Binding Preview}" Margin="5" Grid.RowSpan="5" Grid.Column="5" Grid.Row="1"/>
        <TextBlock TextWrapping="Wrap" VerticalAlignment="Center" Margin="5,10" Height="15" Grid.Column="5"><Run Text="Preview:"/></TextBlock>
    </Grid>
</Window>